Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

461
Vistas
Getting different Pod status from "kubectl get pod" and "kubectl describe pod" command

I created a Pod with two container – one container was successfully created, while other container failed.

Now, when I execute below command then I see that “Status” is “Error”:

C:\Users\test123>kubectl get pod pod3-two-nginx-containers-port-error
NAME                                   READY   STATUS   RESTARTS   AGE
pod3-two-nginx-containers-port-error   1/2     Error    0          134m

But when I execute below command then I see that "Status" is "Running":

C:\Users\test123>kubectl describe pod pod3-two-nginx-containers-port-error
Name:         pod3-two-nginx-containers-port-error
Namespace:    default
Priority:     0
Node:         minikube/192.168.49.2
Start Time:   Thu, 18 Mar 2021 12:50:19 +0530
Labels:       <none>
Annotations:  <none>
Status:       Running
IP:           10.244.0.9
IPs:

Why Kubernetes is showing wrong statuses?

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

Kubernetes is not showing the wrong status.

  • From kubectl get pod <<POD_NAME>> command you get the Pod’s status.
  • From kubectl describe pod <<POD_NAME>> you get the Pod phase’s status. Read more about Pod phases status over here.

kubectl describe pod is giving you status as RUNNING because Pod has been bound to a node + all of the containers have been created + at least one container is still running. Same you can read over the link I have shared over.

kubectl get pod is giving you status as ERROR because Pod is not in healthy state. Right now I do not have link where you can read about what STATUS field means in kubectl get pod but probably I will find and share later.

Another way you can verify this is by running kubectl get pods --field-selector=status.phase=Running command. If you get you Pod listed here then it is another way you can be sure of that status shown in kubectl describe pod command is Pod phase's status.

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda